<?php

namespace Database\Factories;

use App\Models\UserLog;
use Illuminate\Database\Eloquent\Factories\Factory;

class UserLogFactory extends Factory
{
    /**
     * The name of the factory's corresponding model.
     *
     * @var string
     */
    protected $model = UserLog::class;

    /**
     * Define the model's default state.
     *
     * @return array
     */
    public function definition()
    {
        return [
            'user_id' => $this->faker->numberBetween(1, 50),
            'city_id' => $this->faker->numberBetween(1, 36),
            'mer_id' => $this->faker->numberBetween(1, 50),
            'visitor_num' => $this->faker->numberBetween(1, 50),
            'browse_num' => $this->faker->numberBetween(1, 50),
            'register_num' => $this->faker->numberBetween(1, 50),
            'number_num' => $this->faker->numberBetween(1, 50),
            'order_num' => $this->faker->numberBetween(1, 50),
            'recharge_num' => $this->faker->numberBetween(1, 50),
            'list_num' => $this->faker->numberBetween(1, 50),
            'user_num' => $this->faker->numberBetween(1, 50),
            'pay_num' => $this->faker->numberBetween(1, 50),
            'cumulative_num' => $this->faker->numberBetween(1, 50),
            'deal_num' => $this->faker->numberBetween(1, 50),
            'amount' => $this->faker->numberBetween(1, 50),

            'type' => $this->faker->randomElement([
                'officialAccount',
                'applet',
                'h5',
                'pc',
            ]),
            'created_at' => date('Y-m-d H:i:s',$this->faker->numberBetween(1632500000, time())),
            'updated_at' => date('Y-m-d H:i:s',$this->faker->numberBetween(1632500000, time())),
        ];
    }
}
